xcopy
Copies files and directories, including subdirectories.
copy {d: | [d:]path} [d:][path] [options]
Options
{d: | d:path}
The source to copy from. This must be either a drive or a full
path.
d:path
The destination to copy to. If not present, xcopy
assumes the working directory.
/A
Only copy files with the Archive bit set.
/M
Only copy files with the Archive bit set, and turn off the A bit.
/H
Also copies hidden and system files.
/D
The destination is a directory. Cannot be used with /F.
/F
The destination is a file. Cannot be used with /D
/N
Same as /Y.
/P
Prompt for confirmation before each file.
/Q
Doesn't report the filenames of copied files.
/R
Allow read-only files to be overwritten.
/S
Copy subdirectories, except empty ones.
/E
Copy subdirectories, even if empty.
/V
Verify each file as it is written to disk.
/W
Wait before copying any files. Presents a prompt, which you
must first acknowledge.
/Y
No prompting for confirmation of overwriting files.
Notes
The COPYCMD environment variable can be set to make /Y (or /N) the default:
set COPYCMD=/Y
To cancel the /Y for a particular xcopy command, use /-Y at the command line.
The COPYCMD variable also affects the copy command.
Use /Y to change the way both copy and xcopy behave.
Use /N, which copy ignores, to change only the way xcopy behaves.
See Also
Copy
Diskcopy
Copyright © 1998 Jim Hall
This file is derived from the FreeDOS Spec Command HOWTO.
See the file H2Cpying.txt for copying conditions.